package com.neo.base.collectionsTest

import scala.collection.immutable.HashSet;

object SetTest {
  def main(args: Array[String]): Unit = {

    var jetSet =   Set("Hello","BeiJing",5)
    println(jetSet)
    jetSet += "nihao"
    println(jetSet)
    jetSet.foreach(arg  => println(arg))
    jetSet.foreach(println)
    for(arg <- jetSet){
      println(arg)
    }
    println(jetSet.contains("asdasdf"))

    println(jetSet.apply("asd"))

    jetSet.foreach(println)




    val  myhashSet = HashSet("asd","bbb")
     println(myhashSet + "ad")
    for(arg <- myhashSet){
      println(arg)
    }
  }
}
